#ifndef __SYSTEM_H__
#define __SYSTEM_H__
#include "stm8s.h"
#include <stdbool.h>


extern volatile uint32_t  ActionTick;
extern uint8_t Ticker_2sec;



void CallBackTimerInit(void);
void CallBackTimerStart(uint16_t us, uint16_t (*cb)(void));
void CallBackTimerStop(void);

void CallBackTimerStartCC3(uint16_t us, uint16_t (*cb)(void));

void TIM1_CC_IRQHandler(void);

void StopAllTimer(void);

void ActionTickInit(void);
void SysTick_Handler(void);

void Delay_ms(uint16_t ms);
void Delay_us(uint16_t us);
void CE_Delay_us(uint16_t us);
		


#endif

